Doubly robust estimation and causal inference in longitudinal studies with dropout and truncation by death